using System;
using System.Runtime.Serialization;

namespace MiniStock.Entities.Common.Events
{
    [DataContract]
    public sealed class Snapshot: ProtocolEventBase
    {
        [DataMember]
        public string EntityXml { get; set; }

        public EntityBase Entity
        {
            get { return EntityXml.ToEntityBase(); }
            set { EntityXml = value.ToXmlString(); }
        }
    }
}
